3.692 \(\int \frac{\cot ^7(c+d x) \csc ^2(c+d x)}{a+a \sin (c+d x)} \, dx\)

Optimal. Leaf size=91 \[ -\frac{\cot ^8(c+d x)}{8 a d}-\frac{\cot ^6(c+d x)}{6 a d}+\frac{\csc ^7(c+d x)}{7 a d}-\frac{2 \csc ^5(c+d x)}{5 a d}+\frac{\csc ^3(c+d x)}{3 a d} \]

[Out]

-Cot[c + d*x]^6/(6*a*d) - Cot[c + d*x]^8/(8*a*d) + Csc[c + d*x]^3/(3*a*d) - (2*Csc[c + d*x]^5)/(5*a*d) + Csc[c
 + d*x]^7/(7*a*d)

________________________________________________________________________________________

Rubi [A]  time = 0.160092, antiderivative size = 91, normalized size of antiderivative = 1., number of steps used = 7, number of rules used = 5, integrand size = 29, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.172, Rules used = {2835, 2607, 14, 2606, 270} \[ -\frac{\cot ^8(c+d x)}{8 a d}-\frac{\cot ^6(c+d x)}{6 a d}+\frac{\csc ^7(c+d x)}{7 a d}-\frac{2 \csc ^5(c+d x)}{5 a d}+\frac{\csc ^3(c+d x)}{3 a d} \]

Antiderivative was successfully verified.

[In]

Int[(Cot[c + d*x]^7*Csc[c + d*x]^2)/(a + a*Sin[c + d*x]),x]

[Out]

-Cot[c + d*x]^6/(6*a*d) - Cot[c + d*x]^8/(8*a*d) + Csc[c + d*x]^3/(3*a*d) - (2*Csc[c + d*x]^5)/(5*a*d) + Csc[c
 + d*x]^7/(7*a*d)

Rule 2835

Int[(cos[(e_.) + (f_.)*(x_)]^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.))/((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]
), x_Symbol] :> Dist[1/a, Int[Cos[e + f*x]^(p - 2)*(d*Sin[e + f*x])^n, x], x] - Dist[1/(b*d), Int[Cos[e + f*x]
^(p - 2)*(d*Sin[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, n, p}, x] && IntegerQ[(p - 1)/2] && EqQ[a^2
 - b^2, 0] && IntegerQ[n] && (LtQ[0, n, (p + 1)/2] || (LeQ[p, -n] && LtQ[-n, 2*p - 3]) || (GtQ[n, 0] && LeQ[n,
 -p]))

Rule 2607

Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[1/f, Subst[Int[(b*x)
^n*(1 + x^2)^(m/2 - 1), x], x, Tan[e + f*x]], x] /; FreeQ[{b, e, f, n}, x] && IntegerQ[m/2] &&  !(IntegerQ[(n
- 1)/2] && LtQ[0, n, m - 1])

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 2606

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a/f, Subst[
Int[(a*x)^(m - 1)*(-1 + x^2)^((n - 1)/2), x], x, Sec[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n -
1)/2] &&  !(IntegerQ[m/2] && LtQ[0, m, n + 1])

Rule 270

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*(a + b*x^n)^p,
 x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0]

Rubi steps

\begin{align*} \int \frac{\cot ^7(c+d x) \csc ^2(c+d x)}{a+a \sin (c+d x)} \, dx &=-\frac{\int \cot ^5(c+d x) \csc ^3(c+d x) \, dx}{a}+\frac{\int \cot ^5(c+d x) \csc ^4(c+d x) \, dx}{a}\\ &=\frac{\operatorname{Subst}\left (\int x^2 \left (-1+x^2\right )^2 \, dx,x,\csc (c+d x)\right )}{a d}-\frac{\operatorname{Subst}\left (\int x^5 \left (1+x^2\right ) \, dx,x,-\cot (c+d x)\right )}{a d}\\ &=\frac{\operatorname{Subst}\left (\int \left (x^2-2 x^4+x^6\right ) \, dx,x,\csc (c+d x)\right )}{a d}-\frac{\operatorname{Subst}\left (\int \left (x^5+x^7\right ) \, dx,x,-\cot (c+d x)\right )}{a d}\\ &=-\frac{\cot ^6(c+d x)}{6 a d}-\frac{\cot ^8(c+d x)}{8 a d}+\frac{\csc ^3(c+d x)}{3 a d}-\frac{2 \csc ^5(c+d x)}{5 a d}+\frac{\csc ^7(c+d x)}{7 a d}\\ \end{align*}

Mathematica [A]  time = 0.140122, size = 68, normalized size = 0.75 \[ \frac{\csc ^3(c+d x) \left (-105 \csc ^5(c+d x)+120 \csc ^4(c+d x)+280 \csc ^3(c+d x)-336 \csc ^2(c+d x)-210 \csc (c+d x)+280\right )}{840 a d} \]

Antiderivative was successfully verified.

[In]

Integrate[(Cot[c + d*x]^7*Csc[c + d*x]^2)/(a + a*Sin[c + d*x]),x]

[Out]

(Csc[c + d*x]^3*(280 - 210*Csc[c + d*x] - 336*Csc[c + d*x]^2 + 280*Csc[c + d*x]^3 + 120*Csc[c + d*x]^4 - 105*C
sc[c + d*x]^5))/(840*a*d)

________________________________________________________________________________________

Maple [A]  time = 0.167, size = 69, normalized size = 0.8 \begin{align*}{\frac{1}{da} \left ({\frac{1}{7\, \left ( \sin \left ( dx+c \right ) \right ) ^{7}}}-{\frac{1}{8\, \left ( \sin \left ( dx+c \right ) \right ) ^{8}}}-{\frac{2}{5\, \left ( \sin \left ( dx+c \right ) \right ) ^{5}}}-{\frac{1}{4\, \left ( \sin \left ( dx+c \right ) \right ) ^{4}}}+{\frac{1}{3\, \left ( \sin \left ( dx+c \right ) \right ) ^{6}}}+{\frac{1}{3\, \left ( \sin \left ( dx+c \right ) \right ) ^{3}}} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(d*x+c)^7*csc(d*x+c)^9/(a+a*sin(d*x+c)),x)

[Out]

1/d/a*(1/7/sin(d*x+c)^7-1/8/sin(d*x+c)^8-2/5/sin(d*x+c)^5-1/4/sin(d*x+c)^4+1/3/sin(d*x+c)^6+1/3/sin(d*x+c)^3)

________________________________________________________________________________________

Maxima [A]  time = 1.03196, size = 89, normalized size = 0.98 \begin{align*} \frac{280 \, \sin \left (d x + c\right )^{5} - 210 \, \sin \left (d x + c\right )^{4} - 336 \, \sin \left (d x + c\right )^{3} + 280 \, \sin \left (d x + c\right )^{2} + 120 \, \sin \left (d x + c\right ) - 105}{840 \, a d \sin \left (d x + c\right )^{8}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^7*csc(d*x+c)^9/(a+a*sin(d*x+c)),x, algorithm="maxima")

[Out]

1/840*(280*sin(d*x + c)^5 - 210*sin(d*x + c)^4 - 336*sin(d*x + c)^3 + 280*sin(d*x + c)^2 + 120*sin(d*x + c) -
105)/(a*d*sin(d*x + c)^8)

________________________________________________________________________________________

Fricas [A]  time = 1.20344, size = 286, normalized size = 3.14 \begin{align*} -\frac{210 \, \cos \left (d x + c\right )^{4} - 140 \, \cos \left (d x + c\right )^{2} - 8 \,{\left (35 \, \cos \left (d x + c\right )^{4} - 28 \, \cos \left (d x + c\right )^{2} + 8\right )} \sin \left (d x + c\right ) + 35}{840 \,{\left (a d \cos \left (d x + c\right )^{8} - 4 \, a d \cos \left (d x + c\right )^{6} + 6 \, a d \cos \left (d x + c\right )^{4} - 4 \, a d \cos \left (d x + c\right )^{2} + a d\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^7*csc(d*x+c)^9/(a+a*sin(d*x+c)),x, algorithm="fricas")

[Out]

-1/840*(210*cos(d*x + c)^4 - 140*cos(d*x + c)^2 - 8*(35*cos(d*x + c)^4 - 28*cos(d*x + c)^2 + 8)*sin(d*x + c) +
 35)/(a*d*cos(d*x + c)^8 - 4*a*d*cos(d*x + c)^6 + 6*a*d*cos(d*x + c)^4 - 4*a*d*cos(d*x + c)^2 + a*d)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)**7*csc(d*x+c)**9/(a+a*sin(d*x+c)),x)

[Out]

Timed out

________________________________________________________________________________________

Giac [A]  time = 1.32088, size = 89, normalized size = 0.98 \begin{align*} \frac{280 \, \sin \left (d x + c\right )^{5} - 210 \, \sin \left (d x + c\right )^{4} - 336 \, \sin \left (d x + c\right )^{3} + 280 \, \sin \left (d x + c\right )^{2} + 120 \, \sin \left (d x + c\right ) - 105}{840 \, a d \sin \left (d x + c\right )^{8}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^7*csc(d*x+c)^9/(a+a*sin(d*x+c)),x, algorithm="giac")

[Out]

1/840*(280*sin(d*x + c)^5 - 210*sin(d*x + c)^4 - 336*sin(d*x + c)^3 + 280*sin(d*x + c)^2 + 120*sin(d*x + c) -
105)/(a*d*sin(d*x + c)^8)